class bag{
    public String name;
    public String price;

    public bag() {
        System.out.println("这是父类的构造方法");
    }

    static {
        System.out.println("这是父类的静态代码块");
    }
    {
        System.out.println("父类的实例代码块");
    }

    public void show() {
        System.out.println("这是父类的方法");
    }
}
class nike extends bag{
    public String type;
    public String color;

    public nike(){//使用
        name = "nike_bag";
        price = "34.67$";
        color = "grey";
        type = "base";
        System.out.println("这是子类的构造方法");
    }
    {
        System.out.println("子类的示例代码块");
    }


    static{
        System.out.println("这是子类的静态代码块");

    }

    public void show() {
        System.out.println("name = "+name);
        System.out.println("price = " + price);
        System.out.println("color = " + color);
        System.out.println("type = " + type);
    }

    public void show_fu() {
        super.show();
    }
}

final class single_bag extends nike {
    public String size;

    public single_bag(){
        size = "so big";
        super.name = "the one";
        super.price = "33.34$";
        super.color = "black";
        super.type = "one to one";
    }
    public void show(){
        System.out.println("size =" +size);
        System.out.println("name =" +name);
        System.out.println("price =" + price);
        System.out.println("color =" + color);
        System.out.println("type =" + type);

    }

    public void show_nike() {
        super.show();
    }

    public void show_bag() {
        super.show_fu();
    }
}
//class hh extends single_bag{
//
//}
public class biji {

    public static void main(String[] args) {
//        nike hh = new nike();
//        nike hhhh = new nike();
        //hh.show();
        //hh.show_fu();
        single_bag hh = new single_bag();
        hh.show();
        System.out.println("_______");
        hh.show_nike();
        System.out.println("_______");
        hh.show_bag();
    }
}
